package com.ssy.lingxi.logistics.api.fallback;

import com.ssy.lingxi.common.response.ResponseCode;
import com.ssy.lingxi.common.response.Wrapper;
import com.ssy.lingxi.logistics.api.dto.request.CommonIdRequest;
import com.ssy.lingxi.logistics.api.dto.response.LogisticsOrderFeignResponse;
import com.ssy.lingxi.logistics.api.feign.LogisticsOrderControllerFeign;
import org.springframework.stereotype.Component;

import java.util.List;

@Component
public class LogisticsOrderControllerFeignFallback implements LogisticsOrderControllerFeign {

    @Override
    public Wrapper<Void> deleteLogisticsOrder(CommonIdRequest request) {
        return Wrapper.fail(ResponseCode.SERVICE_LOGISTICS_ERROR);
    }

    @Override
    public Wrapper<LogisticsOrderFeignResponse> getLogisticsOrder(Long id) {
        return Wrapper.fail(ResponseCode.SERVICE_LOGISTICS_ERROR);
    }

    @Override
    public Wrapper<List<LogisticsOrderFeignResponse>> listLogisticsOrder(List<Long> ids) {
        return Wrapper.fail(ResponseCode.SERVICE_LOGISTICS_ERROR);
    }
}
